<template>
	<view>
		<view class="goods_list">
			<view class="goods_item" v-for="item in goods">
				<image :src="item.logo"></image>
				<view class="price">
					<text>{{item.price}}</text>
					<text>￥2499</text>
				</view>
				<view class="name">
					<text>{{item.name}}</text>
				</view>
			</view>
		</view>
	</view>
</template>

<script>
	export default {
		data() {
			return {
				goods:[{
					name:'商品一',
					price:'20.36',
					logo:'https://cdn.uviewui.com/uview/album/1.jpg'
				},
				{
					name:'商品二',
					price:'23.36',
					logo:'https://cdn.uviewui.com/uview/album/2.jpg'
				},
				{
					name:'商品三',
					price:'20.36',
					logo:'https://cdn.uviewui.com/uview/album/3.jpg'
				},
				{
					name:'商品四',
					price:'23.36',
					logo:'https://cdn.uviewui.com/uview/album/4.jpg'
				}
				]
			};
		}
	}
</script>

<style lang="scss">
.goods_list{
	padding: 0 15rpx;
	display: flex;
	flex-wrap: wrap;
	justify-content: space-between;
	height: 100%;
	position: relative;
	padding-bottom: calc(var(--window-bottom) + 20px);
	.goods_item{
		background: #fff;
		width: 355rpx;
		margin: 10rpx 0;
		padding: 15rpx;
		box-sizing: border-box;
		image{
			width: 100%;
			height: 150px;
			display: block;
			margin: 5px auto;
		}
		.price{
			color: $main-color-auxiliary-five;
			font-size: 36rpx;
			text:nth-child(2){
				color: #ccc;
				font-size: 28rpx;
				margin-left: 17rpx;
				text-decoration: line-through;
			}
		}
		.name{
			font-size: 28rpx;
			line-height: 50rpx;
			padding-bottom: 15rpx;
			padding-top: 10rpx;
		}
	}
}
</style>
